package zuoye;

public class text1 {

	public static void main(String[] args) {
		//创建一个计算器
		Calculator calculator = new Calculator();
		
		//计算和
		double add=calculator.add(8, 16);
		System.out.println("8+16="+add);
		//计算差
		double subtract=calculator.subtract(82, 64);
		System.out.println("82-64="+subtract);
		//计算积
		double multiply=calculator.multiply(12, 21);
		System.out.println("12x21="+multiply);
		//计算商
		double divide=calculator.divide(12, 3);
		System.out.println("12÷3="+divide);
		//取模
		double delivery=calculator.delivery(10, 4);
		System.out.println("10%2="+delivery);
		//幂运算
		double exponent=calculator.exponent(8, 3);
		System.out.println("8³="+exponent);
		

	}

}
